package ie.dcu.spca.model.sql;

public class categorySQL {
    public static String selectCategoryByName = "SELECT * FROM category WHERE name='%s';";

    public static String insertCategory = "INSERT INTO category VALUES(?,?,?,?,?);";

    public static String selectById = "SELECT * FROM category WHERE id=%d;";

    public static String insertByBean = "INSERT INTO category VALUES(?,?,?,?,?);";

    public static String deleteById = "UPDATE category SET delete_at=? WHERE id=?";

    public static String deleteByBean = "";

    public static String updateByBean = "UPDATE category SET name=?,create_at=?,update_at=?,delete_at=? WHERE id=?;";

    public static String selectMaxId = "SELECT MAX(id) as max FROM category WHERE delete_at==0;";

    public static String existById = "SELECT * FROM category WHERE id=%d;";

    public static String isDeletedById = "SELECT * FROM category WHERE id=%d AND delete_at==0;";

    public static String selectAllBean = "SELECT * FROM category WHERE delete_at==0;";
}
